function data_bootstrap=prepare_data_bootstrap(config)

    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    % INPUT
    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

share=config.share;
p=config.p;
y=config.y;
Z=config.Z;
N=config.N;
p_interest=config.p_interest;
y_interest=config.y_interest;
p_interest_univ=config.p_interest_univ;
y_interest_univ=config.y_interest_univ;
p_grid_constraint=config.p_grid_constraint;
y_grid_constraint=config.y_grid_constraint;
log_y_mu=config.log_y_mu;
log_y_sd=config.log_y_sd;

    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    % DRAW DATA
    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

[share_bootstrap, p_bootstrap, y_bootstrap, Z_bootstrap] = resample_data_flex(N,'with',share, p, y, Z);

    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    % OUTPUT
    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

data_bootstrap.share=share_bootstrap;
data_bootstrap.p=p_bootstrap;
data_bootstrap.y=y_bootstrap;
data_bootstrap.Z=Z_bootstrap;
data_bootstrap.N=N;
data_bootstrap.p_interest=p_interest;
data_bootstrap.y_interest=y_interest;
data_bootstrap.p_interest_univ=p_interest_univ;
data_bootstrap.y_interest_univ=y_interest_univ;
data_bootstrap.log_y_mu=log_y_mu;
data_bootstrap.log_y_sd=log_y_sd;
data_bootstrap.p_grid_constraint=p_grid_constraint;
data_bootstrap.y_grid_constraint=y_grid_constraint;

    %
